{% extends 'order/order_base.html' %}
{% block title %}
    未完成订单
{% endblock %}
{% block content %}
    <ol class="breadcrumb">
      <li><a href="#">首页</a></li>
      <li><a href="#">订单管理</a></li>
      <li class="active">未完成订单</li>
    </ol>
    <table class="table">
        <tr>
            <td>订单编号</td>
            <td>下单日期</td>
            <td>详情</td>
            <td>订单处理</td>
        </tr>
    {% for order in orders %}
        <tr>
            <td>{{ order.order_no }}</td>
            <td>{{ order.order_time }}</td>
            <td><a href="{{url_for("order.order_info_detail",order_no=order.order_no)}}" class="btn btn-primary" role="button">查看详细信息</a> </td>
            <td>
                <form action="{{ url_for("order.done_order") }}">
                    <input type="hidden" name="order_no" value="{{ order.order_no }}">
                    <button type="submit" class="btn btn-success">完成订单</button>
                </form>
            </td>
        </tr>
    {% endfor %}
    </table>
{% endblock %}